home *** CD-ROM | disk | FTP | other *** search
/ Complete Linux / Complete Linux.iso / docs / apps / tex / lametex_.z / lametex_ / lametex / src / Environment.h < prev    next >
Encoding:
C/C++ Source or Header  |  1992-09-02  |  887 b   |  33 lines

  1. /* Environment.h
  2.  *
  3.  * The environment is the current set up of the page in terms of font type,
  4.  * page number, and many other general numbers to keep track of.
  5.  *
  6.  * Copyright 1992 Jonathan Monsarrat. Permission given to freely distribute,
  7.  * edit and use as long as this copyright statement remains intact.
  8.  *
  9.  */
  10.  
  11. #include "Parameter.h"
  12.  
  13. class Environment {
  14.  public:
  15.    // MAKE SURE TO UPDATE THE parms[] array initialization
  16.    // in Environment::Environment
  17.    enum ParamTypes {     //  "Counter" must be first so it "reverts" first.
  18.       PCounter, PDocument, PFont, PJustify, PLength, LastType
  19.    };
  20.  
  21.    Environment();
  22.    Environment(Environment *);
  23.    ~Environment();
  24.    void set(int, int, float, char *);
  25.    void revert(Environment *);
  26.    Param* get_param(int);
  27.  
  28.    float get(int, int, char *);
  29.  private:
  30.    // Same order as enumerator ParamTypes
  31.    Param *params[LastType];
  32. };
  33.